<template>
	<view>
		<view class="detail">
			<textarea name="" placeholder="请输入口味偏好等要求" placeholder-class="mo" v-model="remarks"
				maxlength="50"></textarea>
			<view>0/50</view>
		</view>
		<view class="sub" @click="sub">提交</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				remarks: ''
			}
		},
		onShow() {
			this.remarks = uni.getStorageSync('remarks')
		},
		methods: {
			sub() {
				uni.setStorageSync('remarks', this.remarks);
				uni.navigateBack({
					delta: 1
				})
			}
		}
	}
</script>

<style lang="scss">
	page {
		background-color: #EEFCEB;
	}

	.sub {
		width: 690rpx;
		height: 80rpx;
		border-radius: 10rpx;
		background-color: #84BD00;
		display: flex;
		justify-content: center;
		align-items: center;
		color: #FFFFFF;
		position: fixed;
		bottom: 30rpx;
		left: 30rpx;
	}

	.detail {
		width: 690rpx;
		margin-left: 30rpx;
		background-color: #FFFFFF;
		border-radius: 16px;
		margin-top: 30rpx;
		padding: 30rpx 0;

		textarea {
			width: 630rpx;
			margin-left: 30rpx;
			font-size: 26rpx;
		}

		view {
			width: 630rpx;
			margin-left: 30rpx;
			font-size: 26rpx;
			color: #999999;
		}
	}

	.mo {
		color: #999999;
	}
</style>